From: Carlos Garnacho Date: Mon, 20 Nov 2017 17:54:40 +0000 (+0100) Subject: gdk: Always emit motion after enter X-Git-Tag: archive/raspbian/3.24.39-1+rpi1~1^2~65^2~38^2~137 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/success/%22http:/www.example.com/cgi/success?a=commitdiff_plain;h=3c40b217b9cf2969ab7cb253d23216c699d2626a;p=gtk%2B3.0.git gdk: Always emit motion after enter After a pointer emulating GDK_TOUCH_END event triggering a fake leave notify with GDK_CROSSING_TOUCH_END mode, pointer_under_window will be unset, which will make the next motion/touch_update event to trigger an enter notify event again. Up till there, that's fine, however the motion event is just consumed in favor of the just synthesized enter notify event. This is unexpected to clients like spice-gtk that will only update coordinates from motion events, sending both enter and motion is more consistent with X11 and will make them happy. https://bugzilla.gnome.org/show_bug.cgi?id=791039 --- diff --git a/gdk/gdkwindow.c b/gdk/gdkwindow.c index 79804cdacd..3ac80e910a 100644 --- a/gdk/gdkwindow.c +++ b/gdk/gdkwindow.c @@ -9294,8 +9294,9 @@ proxy_pointer_event (GdkDisplay *display, serial, non_linear); _gdk_display_set_window_under_pointer (display, device, pointer_window); } - else if (source_event->type == GDK_MOTION_NOTIFY || - source_event->type == GDK_TOUCH_UPDATE) + + if (source_event->type == GDK_MOTION_NOTIFY || + source_event->type == GDK_TOUCH_UPDATE) { GdkWindow *event_win; guint evmask;